package com.yiquan.search.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.List;

/**
 * 实体类
 * @author Administrator
 *
 */

@Data
@Document(indexName = "yiquan_video",type = "video")
public class Video implements Serializable{

	@Id
	private Long id;//主键id

	private Long video_id;//视频id
	private String video_url;//视频url
	private String video_description;
	private Long video_uid;//视频作者
	private String video_thumbnail;//视频缩略图
	private Integer thumbs;//点赞数
	private Integer comments;//评论数
	private Integer forwards;//转发数
	private Integer collects;//收藏数
	@JsonFormat(pattern = "yyyy-MM-dd mm:HH:ss")
	@DateTimeFormat(pattern = "yyyy-MM-dd mm:HH:ss")
	private java.util.Date createDate;//发布时间
	private Integer video_status;//视频状态 0：正常 1：仅自己可见 2：删除
	/**
	 * 关于视频的作者拓展信息
	 */

	private String user_nickName; //用户昵称

	private String user_avatar; //用户头像

	private List<String> type; // 类型



}
